<?php
defined('IN_ADMIN') or exit('No permission resources.');
include $this->admin_tpl('header','admin');
?>
<div class="pad_10">
<script language="javascript">
<!--
	$(function(){
		$.formValidator.initConfig({formid:"myform",autotip:true,onerror:function(msg,obj){window.top.art.dialog({content:msg,lock:true,width:'200',height:'50'}, function(){this.close();$(obj).focus();})}});
		$("#cn_name").formValidator({onshow:"请输入中文名称",onfocus:"请输入中文名称",oncorrect:"正确"}).inputValidator({min:1,onerror:"请输入中文名称"});
		$("#en_name").formValidator({onshow:"请输入英文标识",onfocus:"请输入英文标识",oncorrect:"正确"}).inputValidator({min:1,onerror:"请输入英文标识"});
	})
//-->
</script>
<form action="?m=picture&c=source_type&a=edit&id=<?=$id?>" method="post" name="myform" id="myform">
<table cellpadding="2" cellspacing="1" class="table_form" width="100%">
	<tr>
		<th width="100"><?php echo L('menu_parentid')?> :</th>
		<td>
			<select name="source[parentid]" >
				<option value="0"><?php echo L('no_parent_menu')?></option>
				<?php echo $select_categorys;?>
			</select>
		</td>
	</tr>
	<tr>
		<th width="100"><?php echo L('cn_name')?> :</th>
		<td>
			<input name="source[cn_name]" id="cn_name" class="input-text" value="<?=$cn_name?>" type="text" size="40">
		</td>
	</tr>
	<tr>
		<th width="100"><?php echo L('en_name')?> :</th>
		<td>
			<input name="source[en_name]" id="en_name" class="input-text" value="<?=$en_name?>" type="text" size="40">
		</td>
	</tr>
	<tr>
		<th width="100"><?php echo '分类图标';?> :</th>
		<td><?php echo form::images('data[type_icon]', 'type_icon',$type_icon?$type_icon:'', 'picture', '', 40)?></td>
	</tr>
<!-- 	<tr>
		<th><?php echo L('description')?> :</th>
		<td><?php echo form::select(array('1'=>'资讯', '2'=>'视频', '3'=>'图片'), $type, 'name="source[type]"')?></td>
	</tr> -->

<tr>
		<th></th>
		<td>
<input type="hidden"name="from_api" value="<?php echo $_GET['from_api'];?>">
<input type="submit" name="dosubmit" id="dosubmit" class="dialog"
		value=" <?php echo L('submit')?> "></td>
	</tr>

</table>
</form>
</div>
</body>
</html>
<script language="javascript" type="text/javascript">
function AdsType(adstype) {
	$('#SizeFormat').css('display', 'none');
	if(adstype=='0') {
		
	} else if(adstype=='1') {
		$('#SizeFormat').css('display', '');
	}
}
$('#AlignBox').click( function (){
	if($('#AlignBox').attr('checked')) {
		$('#PaddingLeft').attr('disabled', true);
		$('#PaddingTop').attr('disabled', true);
	} else {
		$('#PaddingLeft').attr('disabled', false);
		$('#PaddingTop').attr('disabled', false);
	}
}); 
</script>

<script language="javascript">

</script>